package com.go.manaservice.controller;

import com.go.serviceutils.R;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * @author ZhengYuXiang
 * @version 1.0
 * @date 2021/11/27 2:48 下午
 */
@CrossOrigin
@RestController
@RequestMapping("/manaservice/user")
public class ManagementLoginController {

    //login
    @PostMapping("login")
    public R login(){

//返回token用于路由验证
        return R.ok().data("token","token");
    }
    //info
    @GetMapping("info")
    public R info(){

        return R.ok().data("roles","[admin]").data("name","admin").data("avatar","https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif");
    }
}


